package juc.java8;

import com.sun.xml.internal.ws.commons.xmlutil.Converter;
import jdk.management.resource.ResourceId;

import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
import java.util.concurrent.Callable;

public class CompareDemo {

    public String getAaa() {
        return "aaa";
    }
    public static void main(String[] args) {
//        List<String> names = Arrays.asList("peter", "anna", "mike", "xenia");
//        Collections.sort(names, new Comparator<String>() {
//            @Override
//            public int compare(String a, String b) {
//                return b.compareTo(a);
//            }
//        });
//        Collections.sort(names,(String a, String b)->{
//            return a.compareTo(b);
//        });
//
//        Collections.sort(names,(String a, String b)-> a.compareTo(b));
//
//        names.sort((a,b)->a.compareTo(b));
//        System.out.println(names);

        CompareDemo demo = new CompareDemo();
//        Converter<String, String> converter = something::startsWith;


    }
}
